﻿namespace Modbus.Messages
{
	internal sealed class ReadExceptionStatusResponse : ModbusMessage
	{
		private byte exceptionStatus;

		public override void Read(ModbusReader reader)
		{
			base.Read(reader);

			this.exceptionStatus = reader.ReadByte();
		}

		public override void Write(ModbusWriter writer)
		{
			base.Write(writer);

			writer.Write(this.exceptionStatus);
		}

		public byte ExceptionStatus
		{
			get { return this.exceptionStatus; }
			set { this.exceptionStatus = value; }
		}
	}
}
